package com.zuosh.service;

import com.zuosh.common.Result;
import com.zuosh.domain.UserPost;
import com.zuosh.domain.UserPostExample;

import java.util.List;

/**
 * Created by zuoshuai on 2017/3/17.
 */
public interface PostService {
    /**
     * 帖子列表
     *
     * @param example
     * @return
     */
    Result<List<UserPost>> listPosts(UserPostExample example);

    /**
     * 新增post
     *
     * @param userPost
     * @return
     */
    Result<Long> addPost(UserPost userPost);

    /**
     * 删除post
     *
     * @param userPost
     */
    Result<Boolean> deletePost(UserPost userPost);

}
